Optimal. Leaf size=80 \[ -\frac {\log \left (-\frac {b c-a d}{d (a+b x)}\right ) \left (A+B \log \left (\frac {e (a+b x)}{c+d x}\right )\right )}{b g}+\frac {B \text {Li}_2\left (1+\frac {b c-a d}{d (a+b x)}\right )}{b g} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.14, antiderivative size = 80, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 5, integrand size = 30, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {2542, 2458,
2378, 2370, 2352} \begin {gather*} \frac {B \text {PolyLog}\left (2,\frac {b c-a d}{d (a+b x)}+1\right )}{b g}-\frac {\log \left (-\frac {b c-a d}{d (a+b x)}\right ) \left (B \log \left (\frac {e (a+b x)}{c+d x}\right )+A\right )}{b g} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2352
Rule 2370
Rule 2378
Rule 2458
Rule 2542
Rubi steps
\begin {align*} \int \frac {A+B \log \left (\frac {e (a+b x)}{c+d x}\right )}{a g+b g x} \, dx &=\frac {\left (A+B \log \left (\frac {e (a+b x)}{c+d x}\right )\right ) \log (a g+b g x)}{b g}-\frac {B \int \frac {(c+d x) \left (-\frac {d e (a+b x)}{(c+d x)^2}+\frac {b e}{c+d x}\right ) \log (a g+b g x)}{e (a+b x)} \, dx}{b g}\\ &=\frac {\left (A+B \log \left (\frac {e (a+b x)}{c+d x}\right )\right ) \log (a g+b g x)}{b g}-\frac {B \int \frac {(c+d x) \left (-\frac {d e (a+b x)}{(c+d x)^2}+\frac {b e}{c+d x}\right ) \log (a g+b g x)}{a+b x} \, dx}{b e g}\\ &=\frac {\left (A+B \log \left (\frac {e (a+b x)}{c+d x}\right )\right ) \log (a g+b g x)}{b g}-\frac {B \int \left (\frac {b e \log (a g+b g x)}{a+b x}-\frac {d e \log (a g+b g x)}{c+d x}\right ) \, dx}{b e g}\\ &=\frac {\left (A+B \log \left (\frac {e (a+b x)}{c+d x}\right )\right ) \log (a g+b g x)}{b g}-\frac {B \int \frac {\log (a g+b g x)}{a+b x} \, dx}{g}+\frac {(B d) \int \frac {\log (a g+b g x)}{c+d x} \, dx}{b g}\\ &=\frac {\left (A+B \log \left (\frac {e (a+b x)}{c+d x}\right )\right ) \log (a g+b g x)}{b g}+\frac {B \log \left (\frac {b (c+d x)}{b c-a d}\right ) \log (a g+b g x)}{b g}-B \int \frac {\log \left (\frac {b g (c+d x)}{b c g-a d g}\right )}{a g+b g x} \, dx-\frac {B \text {Subst}\left (\int \frac {g \log (x)}{x} \, dx,x,a g+b g x\right )}{b g^2}\\ &=\frac {\left (A+B \log \left (\frac {e (a+b x)}{c+d x}\right )\right ) \log (a g+b g x)}{b g}+\frac {B \log \left (\frac {b (c+d x)}{b c-a d}\right ) \log (a g+b g x)}{b g}-\frac {B \text {Subst}\left (\int \frac {\log (x)}{x} \, dx,x,a g+b g x\right )}{b g}-\frac {B \text {Subst}\left (\int \frac {\log \left (1+\frac {d x}{b c g-a d g}\right )}{x} \, dx,x,a g+b g x\right )}{b g}\\ &=-\frac {B \log ^2(g (a+b x))}{2 b g}+\frac {\left (A+B \log \left (\frac {e (a+b x)}{c+d x}\right )\right ) \log (a g+b g x)}{b g}+\frac {B \log \left (\frac {b (c+d x)}{b c-a d}\right ) \log (a g+b g x)}{b g}+\frac {B \text {Li}_2\left (-\frac {d (a+b x)}{b c-a d}\right )}{b g}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.03, size = 95, normalized size = 1.19 \begin {gather*} \frac {\log (g (a+b x)) \left (-B \log (g (a+b x))+2 \left (A+B \log \left (\frac {e (a+b x)}{c+d x}\right )+B \log \left (\frac {b (c+d x)}{b c-a d}\right )\right )\right )+2 B \text {Li}_2\left (\frac {d (a+b x)}{-b c+a d}\right )}{2 b g} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(344\) vs.
\(2(79)=158\).
time = 0.60, size = 345, normalized size = 4.31
method | result | size |
derivativedivides | \(-\frac {e \left (a d -c b \right ) \left (\frac {d^{2} A \ln \left (b e -\left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) d \right )}{g \left (a d -c b \right ) b e}-\frac {d^{2} A \ln \left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right )}{g \left (a d -c b \right ) b e}+\frac {d^{2} B \dilog \left (-\frac {-b e +\left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) d}{b e}\right )}{g \left (a d -c b \right ) b e}+\frac {d^{2} B \ln \left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) \ln \left (-\frac {-b e +\left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) d}{b e}\right )}{g \left (a d -c b \right ) b e}-\frac {d^{2} B \ln \left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right )^{2}}{2 g \left (a d -c b \right ) b e}\right )}{d^{2}}\) | \(345\) |
default | \(-\frac {e \left (a d -c b \right ) \left (\frac {d^{2} A \ln \left (b e -\left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) d \right )}{g \left (a d -c b \right ) b e}-\frac {d^{2} A \ln \left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right )}{g \left (a d -c b \right ) b e}+\frac {d^{2} B \dilog \left (-\frac {-b e +\left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) d}{b e}\right )}{g \left (a d -c b \right ) b e}+\frac {d^{2} B \ln \left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) \ln \left (-\frac {-b e +\left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) d}{b e}\right )}{g \left (a d -c b \right ) b e}-\frac {d^{2} B \ln \left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right )^{2}}{2 g \left (a d -c b \right ) b e}\right )}{d^{2}}\) | \(345\) |
risch | \(\frac {A \ln \left (b x +a \right )}{g b}+\frac {B d \ln \left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right )^{2} a}{2 g \left (a d -c b \right ) b}-\frac {B \ln \left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right )^{2} c}{2 g \left (a d -c b \right )}-\frac {B d \dilog \left (-\frac {-b e +\left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) d}{b e}\right ) a}{g \left (a d -c b \right ) b}+\frac {B \dilog \left (-\frac {-b e +\left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) d}{b e}\right ) c}{g \left (a d -c b \right )}-\frac {B d \ln \left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) \ln \left (-\frac {-b e +\left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) d}{b e}\right ) a}{g \left (a d -c b \right ) b}+\frac {B \ln \left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) \ln \left (-\frac {-b e +\left (\frac {b e}{d}+\frac {\left (a d -c b \right ) e}{d \left (d x +c \right )}\right ) d}{b e}\right ) c}{g \left (a d -c b \right )}\) | \(416\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \frac {\int \frac {A}{a + b x}\, dx + \int \frac {B \log {\left (\frac {a e}{c + d x} + \frac {b e x}{c + d x} \right )}}{a + b x}\, dx}{g} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {A+B\,\ln \left (\frac {e\,\left (a+b\,x\right )}{c+d\,x}\right )}{a\,g+b\,g\,x} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________